package com.plumejob.example;

import com.plumejob.boot.SpringContextUtil;
import com.plumejob.executor.annotation.PlumeJob;

/**
 * @author : pdl
 * @date : 2021/3/2 14:15
 */
public class AnnotationJob {


    @PlumeJob(cron = "0/15 * * * * ? ")
    public void annotationJob() {
        System.out.println("annotation job running....");
    }


    @PlumeJob(cron = "0/10 * * * * ? ")
    public void getBeanFromSpring() {
        SpringBean bean = SpringContextUtil.getBean(SpringBean.class);
        System.out.println(bean.getName());
    }
}
